<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.10"/>
<title>wdttb: Wdttb_v3_0</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="HTML_custom.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="xlogo_bg.gif"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">wdttb
   </div>
   <div id="projectbrief">Xilinx SDK Drivers API Documentation</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.10 -->
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Overview</span></a></li>
      <li><a href="annotated.html"><span>Data&#160;Structures</span></a></li>
      <li><a href="globals.html"><span>APIs</span></a></li>
      <li><a href="files.html"><span>File&#160;List</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div class="header">
  <div class="summary">
<a href="#nested-classes">Data Structures</a> &#124;
<a href="#define-members">Macros</a> &#124;
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle">
<div class="title">Wdttb_v3_0</div>  </div>
</div><!--header-->
<div class="contents">
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="nested-classes"></a>
Data Structures</h2></td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_x_wdt_tb___config.html">XWdtTb_Config</a></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_x_wdt_tb.html">XWdtTb</a></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="define-members"></a>
Macros</h2></td></tr>
<tr class="memitem:gafa6b4b0d4c816cd9bd6da3c9fe7caac3"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__wdttb__v3__0.html#gafa6b4b0d4c816cd9bd6da3c9fe7caac3">XWdtTb_ReadReg</a>(BaseAddress,  RegOffset)&#160;&#160;&#160;XWdtTb_In32((BaseAddress) + (RegOffset))</td></tr>
<tr class="separator:gafa6b4b0d4c816cd9bd6da3c9fe7caac3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga36d539f7262d0267924d2ef5612f0cc2"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__wdttb__v3__0.html#ga36d539f7262d0267924d2ef5612f0cc2">XWdtTb_WriteReg</a>(BaseAddress,  RegOffset,  RegisterValue)&#160;&#160;&#160;XWdtTb_Out32((BaseAddress) + (RegOffset), (RegisterValue))</td></tr>
<tr class="separator:ga36d539f7262d0267924d2ef5612f0cc2"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:ga069965d73fae1f4b2b9a27e0212304c0"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__wdttb__v3__0.html#ga069965d73fae1f4b2b9a27e0212304c0">XWdtTb_Initialize</a> (<a class="el" href="struct_x_wdt_tb.html">XWdtTb</a> *InstancePtr, u16 DeviceId)</td></tr>
<tr class="separator:ga069965d73fae1f4b2b9a27e0212304c0"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaab195e280eca1e2985509d954c2e4e52"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__wdttb__v3__0.html#gaab195e280eca1e2985509d954c2e4e52">XWdtTb_Start</a> (<a class="el" href="struct_x_wdt_tb.html">XWdtTb</a> *InstancePtr)</td></tr>
<tr class="separator:gaab195e280eca1e2985509d954c2e4e52"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gad6010e9007dca3b7a1fe928e615b4475"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__wdttb__v3__0.html#gad6010e9007dca3b7a1fe928e615b4475">XWdtTb_Stop</a> (<a class="el" href="struct_x_wdt_tb.html">XWdtTb</a> *InstancePtr)</td></tr>
<tr class="separator:gad6010e9007dca3b7a1fe928e615b4475"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga9b349652da0f47eaac2b1766a1f237fc"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__wdttb__v3__0.html#ga9b349652da0f47eaac2b1766a1f237fc">XWdtTb_IsWdtExpired</a> (<a class="el" href="struct_x_wdt_tb.html">XWdtTb</a> *InstancePtr)</td></tr>
<tr class="separator:ga9b349652da0f47eaac2b1766a1f237fc"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gae1f036194a32943f4e058f51b8f64358"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__wdttb__v3__0.html#gae1f036194a32943f4e058f51b8f64358">XWdtTb_RestartWdt</a> (<a class="el" href="struct_x_wdt_tb.html">XWdtTb</a> *InstancePtr)</td></tr>
<tr class="separator:gae1f036194a32943f4e058f51b8f64358"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga9cd1c306bdea0951ef54d3f854cc0c2c"><td class="memItemLeft" align="right" valign="top">u32&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__wdttb__v3__0.html#ga9cd1c306bdea0951ef54d3f854cc0c2c">XWdtTb_GetTbValue</a> (<a class="el" href="struct_x_wdt_tb.html">XWdtTb</a> *InstancePtr)</td></tr>
<tr class="separator:ga9cd1c306bdea0951ef54d3f854cc0c2c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gad5426484dd69d1a287d1d71dbdda350c"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__wdttb__v3__0.html#gad5426484dd69d1a287d1d71dbdda350c">XWdtTb_SelfTest</a> (<a class="el" href="struct_x_wdt_tb.html">XWdtTb</a> *InstancePtr)</td></tr>
<tr class="separator:gad5426484dd69d1a287d1d71dbdda350c"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h2 class="groupheader">Macro Definition Documentation</h2>
<a class="anchor" id="gafa6b4b0d4c816cd9bd6da3c9fe7caac3"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define XWdtTb_ReadReg</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">BaseAddress, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">RegOffset&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td>&#160;&#160;&#160;XWdtTb_In32((BaseAddress) + (RegOffset))</td>
        </tr>
      </table>
</div><div class="memdoc">

<p><code>#include &lt;<a class="el" href="xwdttb__l_8h.html">xwdttb_l.h</a>&gt;</code></p>

<p>Read from the specified WdtTb device register. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">BaseAddress</td><td>contains the base address of the device. </td></tr>
    <tr><td class="paramname">RegOffset</td><td>contains the offset from the 1st register of the device to select the specific register.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The value read from the register.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>C-Style signature: u32 <a class="el" href="group__wdttb__v3__0.html#gafa6b4b0d4c816cd9bd6da3c9fe7caac3" title="Read from the specified WdtTb device register. ">XWdtTb_ReadReg(u32 BaseAddress, u32 RegOffset)</a>; </dd></dl>

<p>Referenced by <a class="el" href="group__wdttb__v3__0.html#ga9cd1c306bdea0951ef54d3f854cc0c2c">XWdtTb_GetTbValue()</a>, <a class="el" href="group__wdttb__v3__0.html#ga9b349652da0f47eaac2b1766a1f237fc">XWdtTb_IsWdtExpired()</a>, <a class="el" href="group__wdttb__v3__0.html#gae1f036194a32943f4e058f51b8f64358">XWdtTb_RestartWdt()</a>, <a class="el" href="group__wdttb__v3__0.html#gad5426484dd69d1a287d1d71dbdda350c">XWdtTb_SelfTest()</a>, <a class="el" href="group__wdttb__v3__0.html#gaab195e280eca1e2985509d954c2e4e52">XWdtTb_Start()</a>, and <a class="el" href="group__wdttb__v3__0.html#gad6010e9007dca3b7a1fe928e615b4475">XWdtTb_Stop()</a>.</p>

</div>
</div>
<a class="anchor" id="ga36d539f7262d0267924d2ef5612f0cc2"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define XWdtTb_WriteReg</td>
          <td>(</td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">BaseAddress, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">RegOffset, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">&#160;</td>
          <td class="paramname">RegisterValue&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td>&#160;&#160;&#160;XWdtTb_Out32((BaseAddress) + (RegOffset), (RegisterValue))</td>
        </tr>
      </table>
</div><div class="memdoc">

<p><code>#include &lt;<a class="el" href="xwdttb__l_8h.html">xwdttb_l.h</a>&gt;</code></p>

<p>Write to the specified WdtTb device register. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">BaseAddress</td><td>contains the base address of the device. </td></tr>
    <tr><td class="paramname">RegOffset</td><td>contains the offset from the 1st register of the device to select the specific register. </td></tr>
    <tr><td class="paramname">RegisterValue</td><td>is the value to be written to the register.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>None.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>C-Style signature: void XWdtTb_WriteReg(u32 BaseAddress, u32 RegOffset, u32 RegisterValue); </dd></dl>

<p>Referenced by <a class="el" href="group__wdttb__v3__0.html#gae1f036194a32943f4e058f51b8f64358">XWdtTb_RestartWdt()</a>, <a class="el" href="group__wdttb__v3__0.html#gaab195e280eca1e2985509d954c2e4e52">XWdtTb_Start()</a>, and <a class="el" href="group__wdttb__v3__0.html#gad6010e9007dca3b7a1fe928e615b4475">XWdtTb_Stop()</a>.</p>

</div>
</div>
<a class="anchor" id="ga66af9e27001823cc8bc9709fc196d839"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define XWT_CSR0_EWDT1_MASK&#160;&#160;&#160;0x00000002</td>
        </tr>
      </table>
</div><div class="memdoc">

<p><code>#include &lt;<a class="el" href="xwdttb__l_8h.html">xwdttb_l.h</a>&gt;</code></p>

<p>Enable bit 1 Mask. </p>

<p>Referenced by <a class="el" href="group__wdttb__v3__0.html#gaab195e280eca1e2985509d954c2e4e52">XWdtTb_Start()</a>, and <a class="el" href="group__wdttb__v3__0.html#gad6010e9007dca3b7a1fe928e615b4475">XWdtTb_Stop()</a>.</p>

</div>
</div>
<a class="anchor" id="ga238a7c2e868d73205959bfa8cd8fcf67"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define XWT_CSR0_WDS_MASK&#160;&#160;&#160;0x00000004</td>
        </tr>
      </table>
</div><div class="memdoc">

<p><code>#include &lt;<a class="el" href="xwdttb__l_8h.html">xwdttb_l.h</a>&gt;</code></p>

<p>Timer state Mask. </p>

<p>Referenced by <a class="el" href="group__wdttb__v3__0.html#ga9b349652da0f47eaac2b1766a1f237fc">XWdtTb_IsWdtExpired()</a>, <a class="el" href="group__wdttb__v3__0.html#gae1f036194a32943f4e058f51b8f64358">XWdtTb_RestartWdt()</a>, and <a class="el" href="group__wdttb__v3__0.html#gaab195e280eca1e2985509d954c2e4e52">XWdtTb_Start()</a>.</p>

</div>
</div>
<a class="anchor" id="gab723ef9be858b9aeb33600ca2d100bd0"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define XWT_CSR0_WRS_MASK&#160;&#160;&#160;0x00000008</td>
        </tr>
      </table>
</div><div class="memdoc">

<p><code>#include &lt;<a class="el" href="xwdttb__l_8h.html">xwdttb_l.h</a>&gt;</code></p>

<p>Reset status Mask. </p>

<p>Referenced by <a class="el" href="group__wdttb__v3__0.html#ga9b349652da0f47eaac2b1766a1f237fc">XWdtTb_IsWdtExpired()</a>, <a class="el" href="group__wdttb__v3__0.html#gae1f036194a32943f4e058f51b8f64358">XWdtTb_RestartWdt()</a>, and <a class="el" href="group__wdttb__v3__0.html#gaab195e280eca1e2985509d954c2e4e52">XWdtTb_Start()</a>.</p>

</div>
</div>
<a class="anchor" id="ga8a4f0f57f0cf74799a9d17932ebbfca2"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define XWT_CSRX_EWDT2_MASK&#160;&#160;&#160;0x00000001</td>
        </tr>
      </table>
</div><div class="memdoc">

<p><code>#include &lt;<a class="el" href="xwdttb__l_8h.html">xwdttb_l.h</a>&gt;</code></p>

<p>Enable bit 2 Mask. </p>

<p>Referenced by <a class="el" href="group__wdttb__v3__0.html#gaab195e280eca1e2985509d954c2e4e52">XWdtTb_Start()</a>, and <a class="el" href="group__wdttb__v3__0.html#gad6010e9007dca3b7a1fe928e615b4475">XWdtTb_Stop()</a>.</p>

</div>
</div>
<a class="anchor" id="gacd80f8a65e758f3862b655495b41561a"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define XWT_TBR_OFFSET&#160;&#160;&#160;0x8</td>
        </tr>
      </table>
</div><div class="memdoc">

<p><code>#include &lt;<a class="el" href="xwdttb__l_8h.html">xwdttb_l.h</a>&gt;</code></p>

<p>Timebase Register Offset. </p>

<p>Referenced by <a class="el" href="group__wdttb__v3__0.html#ga9cd1c306bdea0951ef54d3f854cc0c2c">XWdtTb_GetTbValue()</a>, and <a class="el" href="group__wdttb__v3__0.html#gad5426484dd69d1a287d1d71dbdda350c">XWdtTb_SelfTest()</a>.</p>

</div>
</div>
<a class="anchor" id="ga7acdd92b397bdfb0e14b649d4525bb2b"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define XWT_TWCSR0_OFFSET&#160;&#160;&#160;0x0</td>
        </tr>
      </table>
</div><div class="memdoc">

<p><code>#include &lt;<a class="el" href="xwdttb__l_8h.html">xwdttb_l.h</a>&gt;</code></p>

<p>Control/Status Register 0 Offset. </p>

<p>Referenced by <a class="el" href="group__wdttb__v3__0.html#ga9b349652da0f47eaac2b1766a1f237fc">XWdtTb_IsWdtExpired()</a>, <a class="el" href="group__wdttb__v3__0.html#gae1f036194a32943f4e058f51b8f64358">XWdtTb_RestartWdt()</a>, <a class="el" href="group__wdttb__v3__0.html#gaab195e280eca1e2985509d954c2e4e52">XWdtTb_Start()</a>, and <a class="el" href="group__wdttb__v3__0.html#gad6010e9007dca3b7a1fe928e615b4475">XWdtTb_Stop()</a>.</p>

</div>
</div>
<a class="anchor" id="ga5342d8af54e416c23b56a3dd9904e62b"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define XWT_TWCSR1_OFFSET&#160;&#160;&#160;0x4</td>
        </tr>
      </table>
</div><div class="memdoc">

<p><code>#include &lt;<a class="el" href="xwdttb__l_8h.html">xwdttb_l.h</a>&gt;</code></p>

<p>Control/Status Register 1 Offset. </p>

<p>Referenced by <a class="el" href="group__wdttb__v3__0.html#gaab195e280eca1e2985509d954c2e4e52">XWdtTb_Start()</a>, and <a class="el" href="group__wdttb__v3__0.html#gad6010e9007dca3b7a1fe928e615b4475">XWdtTb_Stop()</a>.</p>

</div>
</div>
<h2 class="groupheader">Function Documentation</h2>
<a class="anchor" id="ga9cd1c306bdea0951ef54d3f854cc0c2c"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">u32 XWdtTb_GetTbValue </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="struct_x_wdt_tb.html">XWdtTb</a> *&#160;</td>
          <td class="paramname"><em>InstancePtr</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p><code>#include &lt;<a class="el" href="xwdttb_8c.html">xwdttb.c</a>&gt;</code></p>

<p>Returns the current contents of the timebase. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">InstancePtr</td><td>is a pointer to the <a class="el" href="struct_x_wdt_tb.html" title="The XWdtTb driver instance data. ">XWdtTb</a> instance to be worked on.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The contents of the timebase.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>References <a class="el" href="group__wdttb__v3__0.html#gafa6b4b0d4c816cd9bd6da3c9fe7caac3">XWdtTb_ReadReg</a>, and <a class="el" href="group__wdttb__v3__0.html#gacd80f8a65e758f3862b655495b41561a">XWT_TBR_OFFSET</a>.</p>

</div>
</div>
<a class="anchor" id="ga069965d73fae1f4b2b9a27e0212304c0"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int XWdtTb_Initialize </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="struct_x_wdt_tb.html">XWdtTb</a> *&#160;</td>
          <td class="paramname"><em>InstancePtr</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">u16&#160;</td>
          <td class="paramname"><em>DeviceId</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p><code>#include &lt;<a class="el" href="xwdttb_8c.html">xwdttb.c</a>&gt;</code></p>

<p>Initialize a specific watchdog timer/timebase instance/driver. </p>
<p>This function must be called before other functions of the driver are called.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">InstancePtr</td><td>is a pointer to the <a class="el" href="struct_x_wdt_tb.html" title="The XWdtTb driver instance data. ">XWdtTb</a> instance to be worked on. </td></tr>
    <tr><td class="paramname">DeviceId</td><td>is the unique id of the device controlled by this <a class="el" href="struct_x_wdt_tb.html" title="The XWdtTb driver instance data. ">XWdtTb</a> instance. Passing in a device id associates the generic <a class="el" href="struct_x_wdt_tb.html" title="The XWdtTb driver instance data. ">XWdtTb</a> instance to a specific device, as chosen by the caller or application developer.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><ul>
<li>XST_SUCCESS if initialization was successful</li>
<li>XST_DEVICE_IS_STARTED if the device has already been started</li>
<li>XST_DEVICE_NOT_FOUND if the configuration for device ID was not found</li>
</ul>
</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>References <a class="el" href="struct_x_wdt_tb___config.html#a46d8b50440000851ab0ffc4b7be3aab4">XWdtTb_Config::BaseAddr</a>.</p>

</div>
</div>
<a class="anchor" id="ga9b349652da0f47eaac2b1766a1f237fc"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int XWdtTb_IsWdtExpired </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="struct_x_wdt_tb.html">XWdtTb</a> *&#160;</td>
          <td class="paramname"><em>InstancePtr</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p><code>#include &lt;<a class="el" href="xwdttb_8c.html">xwdttb.c</a>&gt;</code></p>

<p>Check if the watchdog timer has expired. </p>
<p>This function is used for polled mode and it is also used to check if the last reset was caused by the watchdog timer.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">InstancePtr</td><td>is a pointer to the <a class="el" href="struct_x_wdt_tb.html" title="The XWdtTb driver instance data. ">XWdtTb</a> instance to be worked on.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>TRUE if the watchdog has expired, and FALSE otherwise.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>References <a class="el" href="group__wdttb__v3__0.html#gafa6b4b0d4c816cd9bd6da3c9fe7caac3">XWdtTb_ReadReg</a>, <a class="el" href="group__wdttb__v3__0.html#ga238a7c2e868d73205959bfa8cd8fcf67">XWT_CSR0_WDS_MASK</a>, <a class="el" href="group__wdttb__v3__0.html#gab723ef9be858b9aeb33600ca2d100bd0">XWT_CSR0_WRS_MASK</a>, and <a class="el" href="group__wdttb__v3__0.html#ga7acdd92b397bdfb0e14b649d4525bb2b">XWT_TWCSR0_OFFSET</a>.</p>

</div>
</div>
<a class="anchor" id="gae1f036194a32943f4e058f51b8f64358"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void XWdtTb_RestartWdt </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="struct_x_wdt_tb.html">XWdtTb</a> *&#160;</td>
          <td class="paramname"><em>InstancePtr</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p><code>#include &lt;<a class="el" href="xwdttb_8c.html">xwdttb.c</a>&gt;</code></p>

<p>Restart the watchdog timer. </p>
<p>An application needs to call this function periodically to keep the timer from asserting the reset output.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">InstancePtr</td><td>is a pointer to the <a class="el" href="struct_x_wdt_tb.html" title="The XWdtTb driver instance data. ">XWdtTb</a> instance to be worked on.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>None.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>References <a class="el" href="group__wdttb__v3__0.html#gafa6b4b0d4c816cd9bd6da3c9fe7caac3">XWdtTb_ReadReg</a>, <a class="el" href="group__wdttb__v3__0.html#ga36d539f7262d0267924d2ef5612f0cc2">XWdtTb_WriteReg</a>, <a class="el" href="group__wdttb__v3__0.html#ga238a7c2e868d73205959bfa8cd8fcf67">XWT_CSR0_WDS_MASK</a>, <a class="el" href="group__wdttb__v3__0.html#gab723ef9be858b9aeb33600ca2d100bd0">XWT_CSR0_WRS_MASK</a>, and <a class="el" href="group__wdttb__v3__0.html#ga7acdd92b397bdfb0e14b649d4525bb2b">XWT_TWCSR0_OFFSET</a>.</p>

</div>
</div>
<a class="anchor" id="gad5426484dd69d1a287d1d71dbdda350c"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int XWdtTb_SelfTest </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="struct_x_wdt_tb.html">XWdtTb</a> *&#160;</td>
          <td class="paramname"><em>InstancePtr</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p><code>#include &lt;<a class="el" href="xwdttb_8h.html">xwdttb.h</a>&gt;</code></p>

<p>Run a self-test on the timebase. </p>
<p>This test verifies that the timebase is incrementing. The watchdog timer is not tested due to the time required to wait for the watchdog timer to expire. The time consumed by this test is dependant on the system clock and the configuration of the dividers in for the input clock of the timebase.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">InstancePtr</td><td>is a pointer to the <a class="el" href="struct_x_wdt_tb.html" title="The XWdtTb driver instance data. ">XWdtTb</a> instance to be worked on.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><ul>
<li>XST_SUCCESS if self-test was successful</li>
<li>XST_WDTTB_TIMER_FAILED if the timebase is not incrementing</li>
</ul>
</dd></dl>
<dl class="section note"><dt>Note</dt><dd>None. </dd></dl>

<p>References <a class="el" href="group__wdttb__v3__0.html#gafa6b4b0d4c816cd9bd6da3c9fe7caac3">XWdtTb_ReadReg</a>, and <a class="el" href="group__wdttb__v3__0.html#gacd80f8a65e758f3862b655495b41561a">XWT_TBR_OFFSET</a>.</p>

</div>
</div>
<a class="anchor" id="gaab195e280eca1e2985509d954c2e4e52"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void XWdtTb_Start </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="struct_x_wdt_tb.html">XWdtTb</a> *&#160;</td>
          <td class="paramname"><em>InstancePtr</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p><code>#include &lt;<a class="el" href="xwdttb_8c.html">xwdttb.c</a>&gt;</code></p>

<p>Start the watchdog timer of the device. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">InstancePtr</td><td>is a pointer to the <a class="el" href="struct_x_wdt_tb.html" title="The XWdtTb driver instance data. ">XWdtTb</a> instance to be worked on.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>None.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>The Timebase is reset to 0 when the Watchdog Timer is started. The Timebase is always incrementing </dd></dl>

<p>References <a class="el" href="group__wdttb__v3__0.html#gafa6b4b0d4c816cd9bd6da3c9fe7caac3">XWdtTb_ReadReg</a>, <a class="el" href="group__wdttb__v3__0.html#ga36d539f7262d0267924d2ef5612f0cc2">XWdtTb_WriteReg</a>, <a class="el" href="group__wdttb__v3__0.html#ga66af9e27001823cc8bc9709fc196d839">XWT_CSR0_EWDT1_MASK</a>, <a class="el" href="group__wdttb__v3__0.html#ga238a7c2e868d73205959bfa8cd8fcf67">XWT_CSR0_WDS_MASK</a>, <a class="el" href="group__wdttb__v3__0.html#gab723ef9be858b9aeb33600ca2d100bd0">XWT_CSR0_WRS_MASK</a>, <a class="el" href="group__wdttb__v3__0.html#ga8a4f0f57f0cf74799a9d17932ebbfca2">XWT_CSRX_EWDT2_MASK</a>, <a class="el" href="group__wdttb__v3__0.html#ga7acdd92b397bdfb0e14b649d4525bb2b">XWT_TWCSR0_OFFSET</a>, and <a class="el" href="group__wdttb__v3__0.html#ga5342d8af54e416c23b56a3dd9904e62b">XWT_TWCSR1_OFFSET</a>.</p>

</div>
</div>
<a class="anchor" id="gad6010e9007dca3b7a1fe928e615b4475"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int XWdtTb_Stop </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="struct_x_wdt_tb.html">XWdtTb</a> *&#160;</td>
          <td class="paramname"><em>InstancePtr</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p><code>#include &lt;<a class="el" href="xwdttb_8c.html">xwdttb.c</a>&gt;</code></p>

<p>Disable the watchdog timer. </p>
<p>It is the caller's responsibility to disconnect the interrupt handler of the watchdog timer from the interrupt source, typically an interrupt controller, and disable the interrupt in the interrupt controller.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">InstancePtr</td><td>is a pointer to the <a class="el" href="struct_x_wdt_tb.html" title="The XWdtTb driver instance data. ">XWdtTb</a> instance to be worked on.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><ul>
<li>XST_SUCCESS if the watchdog was stopped successfully</li>
<li>XST_NO_FEATURE if the watchdog cannot be stopped</li>
</ul>
</dd></dl>
<dl class="section note"><dt>Note</dt><dd></dd></dl>
<p>The hardware configuration controls this functionality. If it is not allowed by the hardware the failure will be returned and the timer will continue without interruption. </p>

<p>References <a class="el" href="group__wdttb__v3__0.html#gafa6b4b0d4c816cd9bd6da3c9fe7caac3">XWdtTb_ReadReg</a>, <a class="el" href="group__wdttb__v3__0.html#ga36d539f7262d0267924d2ef5612f0cc2">XWdtTb_WriteReg</a>, <a class="el" href="group__wdttb__v3__0.html#ga66af9e27001823cc8bc9709fc196d839">XWT_CSR0_EWDT1_MASK</a>, <a class="el" href="group__wdttb__v3__0.html#ga8a4f0f57f0cf74799a9d17932ebbfca2">XWT_CSRX_EWDT2_MASK</a>, <a class="el" href="group__wdttb__v3__0.html#ga7acdd92b397bdfb0e14b649d4525bb2b">XWT_TWCSR0_OFFSET</a>, and <a class="el" href="group__wdttb__v3__0.html#ga5342d8af54e416c23b56a3dd9904e62b">XWT_TWCSR1_OFFSET</a>.</p>

</div>
</div>
<h2 class="groupheader">Variable Documentation</h2>
<a class="anchor" id="gaa17c2f5fdfae5db7362900b7ea2f6b73"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="struct_x_wdt_tb___config.html">XWdtTb_Config</a> XWdtTb_ConfigTable[XPAR_XWDTTB_NUM_INSTANCES]</td>
        </tr>
      </table>
</div><div class="memdoc">

<p><code>#include &lt;<a class="el" href="xwdttb__g_8c.html">xwdttb_g.c</a>&gt;</code></p>
<b>Initial value:</b><div class="fragment"><div class="line">= {</div>
<div class="line">        {</div>
<div class="line">         XPAR_WDTTB_0_DEVICE_ID,</div>
<div class="line">         XPAR_WDTTB_0_BASEADDR}</div>
<div class="line">}</div>
</div><!-- fragment -->
<p>This table contains configuration information for each watchdog timer device in the system. </p>

</div>
</div>
<a class="anchor" id="ga063bf798221700733fe7126926daa3b1"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="struct_x_wdt_tb___config.html">XWdtTb_Config</a> XWdtTb_ConfigTable[]</td>
        </tr>
      </table>
</div><div class="memdoc">

<p><code>#include &lt;<a class="el" href="xwdttb_8c.html">xwdttb.c</a>&gt;</code></p>

<p>This table contains configuration information for each watchdog timer device in the system. </p>

</div>
</div>
</div><!-- contents -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="footer">Copyright &copy; 2015 Xilinx Inc. All rights reserved.</li>
  </ul>
</div>
</body>
</html>
